home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d12
/
v9n20.arc
/
PLUS_UD1.ASP
< prev
next >
Wrap
Text File
|
1990-10-29
|
7KB
|
239 lines
;
; PC MagNet Utilities Database Down Load Script,
; written for/with Procomm Plus v1.1b,
; by Rick Ayre 6.2.90.
;
ASSIGN S1 "EMPTY" ; create five string variables,
ASSIGN S2 "EMPTY" ; and place the string EMPTY
ASSIGN S3 "EMPTY" ; in each
ASSIGN S4 "EMPTY"
ASSIGN S5 "EMPTY"
Main_Menu: ; routine that paints the following message on the screen
CLEAR
MESSAGE " "
MESSAGE " "
MESSAGE " ┌┤ PC MagNet Utilities Database ├┐"
MESSAGE " │ │"
MESSAGE " │ File to down load: │"
MESSAGE " │ ____________ │"
MESSAGE " │ │"
MESSAGE " └────────────────────────────────┘"
MESSAGE "^G"
MESSAGE "^G"
Get_File_Name: ; label for use by default case
LOCATE 10,54 ; position cursor
MESSAGE " " ; clear prompt area
LOCATE 5,33 ; reposition cursor
GET S0 12 ; get users choice
SWITCH S0
CASE "_NULL" ; check to see if there IS a file name
GOTO What_Now
ENDCASE
DEFAULT
ISFILE S0 ; check to see if file already exists
IF SUCCESS
CLEAR
MESSAGE "File Exists - Get Anyway? (Y/N)"
GET S7
SWITCH S7
CASE "N"
GOTO Main_Menu
ENDCASE
DEFAULT
GOTO File_Names
ENDCASE
ENDSWITCH
ELSE
GOTO File_Names
ENDCASE
ENDSWITCH
File_Names: ; routine to grab the file names and assign them to S1-S5
FIND S1 "EMPTY" ; check to see if S1 is empty
IF FOUND ; if so,
ASSIGN S1 S0 ; put new file name in S1
GOTO Get_Another ; and jumpt to next question
ENDIF ; if not
FIND S2 "EMPTY" ; check to see if S2 is empty
IF FOUND ; etc.
ASSIGN S2 S0
GOTO Get_Another
ENDIF
FIND S3 "EMPTY"
IF FOUND
ASSIGN S3 S0
GOTO Get_Another
ENDIF
FIND S4 "EMPTY"
IF FOUND
ASSIGN S4 S0
GOTO Get_Another
ENDIF
FIND S5 "EMPTY"
IF FOUND
ASSIGN S5 S0
ELSE
CLEAR
GOTO Log_On
ENDIF
Get_Another: ; routine to ask if user wants another file
CLEAR
MESSAGE " "
MESSAGE " "
MESSAGE " ┌┤ Down Load Another? ├┐"
MESSAGE " │ (Y/N): _ │"
MESSAGE " └──────────────────────┘"
MESSAGE "^G"
LOCATE 3 37
GET S8 1
FIND S5 "EMPTY" ; check to see if S5 is empty
IF NOT FOUND ; if not send user the following message
CLEAR
MESSAGE "Sorry, I can only down load five files at a time!"
PAUSE 5
GOTO Log_On
ENDIF
SWITCH S8
CASE "Y"
GOTO Main_Menu
ENDCASE
CASE "N"
GOTO Log_On
ENDCASE
ENDSWITCH
What_Now: ; routine to recover from off line errors
CLEAR
MESSAGE "End This Script? (Y/N): "
GET S9 1
SWITCH S9
CASE "Y"
GOTO Get_Off
ENDCASE
CASE "N"
GOTO Main_Menu
ENDCASE
ENDSWITCH
Log_On: ; routine to log on to CompuServe
FIND S1 "EMPTY"
IF FOUND
GOTO Get_Out
ENDIF
CLEAR
IF NOT LINKED
DIAL "1" ; your Dialing Directory number goes in place of 1
PAUSE 1
ENDIF
TRANSMIT "^M"
WAITFOR "ost Name: " 4
IF WAITFOR
PAUSE 1
TRANSMIT "cis^M"
ELSE
TRANSMIT "^M"
ENDIF
WAITFOR "User ID: "
PAUSE 1
TRANSMIT "######,###^M" ; your UserID goes in place of "#"s
WAITFOR "Password: "
PAUSE 1
TRANSMIT "******.*******" ; your password goes in place of "*"s
CLEAR
PAUSE 2
WAITFOR "New"
TRANSMIT "^C"
WAITFOR "M for prior MENU"
Get_File: ; routine to navigate the PC MagNet Utilites Database
ASSIGN S0 S1 ; and down load a file
TRANSMIT "GO UTILIT^M"
WAITFOR "Utilities Database"
TRANSMIT "^C"
WAITFOR "M for prior MENU"
TRANSMIT "4^M"
WAITFOR "ample, DR.COM): "
PAUSE 1
TRANSMIT S0
TRANSMIT "^M"
WAITFOR "Utility Type:" 10
IF WAITFOR
TRANSMIT "^C"
WAITFOR "M for prior MENU"
TRANSMIT "Y^M"
ELSE
GOTO Error
ENDIF
WAITFOR "begin transfer" 15
PAUSE 1
TRANSMIT "^M"
WAITFOR "Kermit"
PAUSE 1
TRANSMIT "5^M"
WAITFOR "Downloading..." ;**** This line, and the line that begins with GETFILE
PAUSE 2
GETFILE CISB ;**** must both be deleted if you set ENQ = CIS B in Terminal Setup
WAITFOR "^M"
PAUSE 1
Give_File_Name: ; routine to pass file names to down load routine
FIND S5 "EMPTY" ; check to see if S5 is empty
IF NOT FOUND ; if not
ASSIGN S1 S5 ; put the file name in S1
ASSIGN S5 "EMPTY" ; and put empty in S5
GOTO Get_File ; if S5 is
ENDIF ; empty
FIND S4 "EMPTY" ; check to see if S4 is empty
IF NOT FOUND ; etc.
ASSIGN S1 S4
ASSIGN S4 "EMPTY"
GOTO Get_File
ENDIF
FIND S3 "EMPTY"
IF NOT FOUND
ASSIGN S1 S3
ASSIGN S3 "EMPTY"
GOTO Get_File
ENDIF
FIND S2 "EMPTY"
IF NOT FOUND
ASSIGN S1 S2
ASSIGN S2 "EMPTY"
GOTO Get_File
ELSE
GOTO Get_Off
ENDIF
Error: ; routine to recover from online errors
CLEAR
MESSAGE "^G"
MESSAGE "Can't Find That File"
MESSAGE "Continue With Next? (Y/N)"
GET S6
SWITCH S6
CASE "Y"
GOTO Give_File_Name
ENDCASE
DEFAULT
GOTO Get_Off
ENDCASE
ENDSWITCH
Get_Off: ; routine to log off
TRANSMIT "OFF^M"
PAUSE 3
TRANSMIT "OFF^M"
HANGUP
Get_Out: ; routine to end script
CLEAR
MESSAGE "Thanks for using PC MagNet."
MESSAGE "^G"
EXIT